import request from '@/utils/request'

export function departmentAdd(data) {
  return request({
    url: '/sys/department',
    method: 'post',
    data
  }).then(res => {
    return res
  })
}

export function assetsRecycle(data) {
  return request({
    url: '/assets/software/recycle',
    method: 'get',
    params: data
  }).then(res => {
    console.log(res)
    return res
  })
}
export function departmentPut(data) {
  return request({
    url: '/sys/department',
    method: 'put',
    data
  }).then(res => {
    return res
  })
}

export function departmentList(data) {
  return request({
    url: '/sys/department/list',
    method: 'post',
    data
  }).then(res => {
    return res
  })
}

export function departmentPage(data) {
  return request({
    url: '/sys/department/page',
    method: 'post',
    data
  }).then(res => {
    return res
  })
}

export function departmentDel(data) {
  return request({
    url: '/sys/department',
    method: 'delete',
    data
  }).then(res => {
    console.log(res)
    return res
  })
}
